/*
 * @Description: 角色实体
 * @Author: Haor
 * @Date: 2022-05-11 12:05:28
 * @LastEditTime: 2022-05-11 12:24:53
 * @LastEditors: Haor
 */
import { Column, Entity, PrimaryGeneratedColumn } from 'typeorm'
import { PublicEntity } from '@entities/public.entity'

@Entity({ name: 'sys_role' }) //数据表的名字
export class Role extends PublicEntity {
	@PrimaryGeneratedColumn({ comment: '主键id' })
    role_id: number

	// 角色名称
	@Column({ comment: '角色名称' })
	name: string

	// 角色级别
	@Column({ comment: '角色级别' })
	level: number

	// 描述信息
	@Column({ comment: '描述信息' })
	description: string

	// 数据权限
	@Column({ name: 'data_scope', comment: '数据权限' })
	dataScope: string
}
